package cn.dalgen.mybatis.gen.model.db;

import bsh.StringUtil;
import org.apache.commons.lang.StringUtils;

public class DataSourceConfig {
    
    private String dataSource ;
    private String sessionFactory ;
    private String transactionManager ;
    private String transactionTemplate ;
    private String sqlSessionTemplate ;
    
    public String getDataSource() {
        return dataSource;
    }
    
    public void setDataSource(String dataSource) {
        this.dataSource = StringUtils.isBlank(dataSource)?this.dataSource :dataSource;
    }
    
    public String getSessionFactory() {
        return sessionFactory;
    }
    
    public void setSessionFactory(String sessionFactory) {
        this.sessionFactory = StringUtils.isBlank(sessionFactory)?this.sessionFactory:sessionFactory;
    }
    
    public String getTransactionManager() {
        return transactionManager;
    }
    
    public void setTransactionManager(String transactionManager) {
        this.transactionManager = StringUtils.isBlank(transactionManager)?this.transactionManager:transactionManager;
    }
    
    public String getTransactionTemplate() {
        return transactionTemplate;
    }
    
    public void setTransactionTemplate(String transactionTemplate) {
        this.transactionTemplate = StringUtils.isBlank(transactionTemplate)?this.transactionTemplate:transactionTemplate;
    }
    
    public String getSqlSessionTemplate() {
        return sqlSessionTemplate;
    }
    
    public void setSqlSessionTemplate(String sqlSessionTemplate) {
        this.sqlSessionTemplate = StringUtils.isBlank(sqlSessionTemplate)?this.sqlSessionTemplate:sqlSessionTemplate;
    }
}
